home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Atari Compendium
/
The Atari Compendium (Toad Computers) (1994).iso
/
files
/
umich
/
tex
/
td187src.lzh
/
MAGICVDI.D
< prev
next >
Wrap
Text File
|
1991-06-08
|
15KB
|
447 lines
(*######################################################################
MAGIC Modula's All purpose GEM Interface Cadre
¯ ¯ ¯ ¯ ¯
########################################################################
VDI Virtual Device Interface Interface for Modula-2
########################################################################
V2.00 17.10.90 Peter Hellinger Anpassung an neues MagicSys
V1.02 30.06.90 Peter Hellinger tCtrlArray wurde auf 255 Elemente
erweitert
V1.01 18.06.90 Peter Hellinger Konstanten ergänzt
V1.00 (C) by Peter Hellinger
######################################################################*)
DEFINITION MODULE MagicVDI;
FROM SYSTEM IMPORT ADDRESS;
FROM MagicSys IMPORT Nil, Null,
Bit0, Bit1, Bit2, Bit3, Bit4, Bit5, Bit6, Bit7,
Bit8, Bit9, Bit10, Bit11, Bit12, Bit13, Bit14, Bit15,
LOC, Byte, ByteSet, sWORD, sINTEGER, sCARDINAL, sBITSET,
lWORD, lINTEGER, lCARDINAL, lBITSET;
(*-- VDI-Parameter ---------------------------------------------------*)
TYPE tWorkIn = ARRAY [0..10] OF sINTEGER;
tWorkOut = ARRAY [0..57] OF sINTEGER;
tPxyArray = ARRAY [0..3] OF sINTEGER;
tBigPxyArray = ARRAY [0..7] OF sINTEGER;
tMouseArray = ARRAY [0..38] OF sINTEGER;
tSmallArray = ARRAY [0..1] OF sINTEGER;
tRGBArray = ARRAY [0..2] OF sINTEGER;
tTextAttrArray = ARRAY [0..9] OF sINTEGER;
tFontName = ARRAY [0..31] OF CHAR;
tDistanceArray = ARRAY [0..4] OF sINTEGER;
tFilmName = ARRAY [0..124] OF CHAR;
tFilmIndex = ARRAY [0..7],[0..1] OF sINTEGER;
tCtrlArray = ARRAY [0..255] OF sINTEGER;
VAR VDIControl: ARRAY [0..11] OF sINTEGER;
VDIIntIn: tCtrlArray;
VDIPtsIn: tCtrlArray;
VDIIntOut: tCtrlArray;
VDIPtsOut: tCtrlArray;
VAR VDIPB: RECORD
control: POINTER TO ARRAY [0..11] OF sINTEGER;
intin: POINTER TO tCtrlArray;
ptsin: POINTER TO tCtrlArray;
intout: POINTER TO tCtrlArray;
ptsout: POINTER TO tCtrlArray;
END;
PROCEDURE VDICall (ctrl0, ctrl1, ctrl3, ctrl5, ctrl6: sINTEGER);
PROCEDURE VqGDos(): BOOLEAN;
(*-- VDI-Attrib ------------------------------------------------------*)
CONST REPLACE = 1; (* Schreibmodi *)
TRANSPARENT = 2;
XOR = 3;
REVTRANSPARENT = 4;
PROCEDURE SetWritemode (handle, mode: sINTEGER): sINTEGER;
PROCEDURE SetColor (handle, index: sINTEGER; VAR rgb: ARRAY OF LOC);
CONST Line = 1; (* Linienstil *)
LongDash = 2;
Dot = 3;
DashDot = 4;
Dash = 5;
DashDotDot = 6;
User = 7;
PROCEDURE SetLinetype (handle, type: sINTEGER): sINTEGER;
PROCEDURE SetUserlinestyle (handle: sINTEGER; style: ARRAY OF LOC);
PROCEDURE SetLinewidth (handle, width: sINTEGER): sINTEGER;
PROCEDURE SetLinecolor (handle, color: sINTEGER): sINTEGER;
CONST Cornerd = 0; (* Linien-Endtypen *)
Arrow = 1;
Rounded = 2;
PROCEDURE SetLineEndstyles (handle, begin, end: sINTEGER);
CONST Point = 1; (* Markertypen *)
Plus = 2;
Star = 3;
Square = 4;
Cross = 5;
Diamond = 6;
PROCEDURE SetMarkertype (handle, type: sINTEGER): sINTEGER;
PROCEDURE SetMarkerheight (handle, height: sINTEGER): sINTEGER;
PROCEDURE SetMarkercolor (handle, index: sINTEGER): sINTEGER;
PROCEDURE SetCharheight (handle, h: sINTEGER; VAR ch, cw, bh, bw: sINTEGER);
PROCEDURE SetCharpoints (handle, h: sINTEGER; VAR ch, cw, bh, bw: sINTEGER): sINTEGER;
PROCEDURE SetCharbaseline (handle, angle: sINTEGER): sINTEGER;
PROCEDURE SetTextface (handle, font: sINTEGER): sINTEGER;
PROCEDURE SetTextcolor (handle, index: sINTEGER): sINTEGER;
CONST Fat = Bit0; (* Text-Effekte *)
Light = Bit1;
Italic = Bit2;
Underline = Bit3;
Outline = Bit4;
Shadowed = Bit5;
PROCEDURE SetTexteffect (handle: sINTEGER; effect: sBITSET): sBITSET;
CONST LeftJust = 0;
Centerd = 1;
RightJust = 2;
CONST BaseJust = 0;
HalfJust = 1;
AscentJust = 2;
BottomJust = 3;
DescentJust = 4;
TopJust = 5;
PROCEDURE SetTextalignment (handle, hin, vin: sINTEGER; VAR hout, vout: sINTEGER);
CONST None = 0; (* Fülltypen *)
Full = 1;
Pattern = 2;
Hatch = 3;
UserFill = 4;
PROCEDURE SetFillinterior (handle: sINTEGER; index: sINTEGER): sINTEGER;
PROCEDURE SetFillstyle (handle, style: sINTEGER): sINTEGER;
PROCEDURE SetFillcolor (handle, index: sINTEGER): sINTEGER;
PROCEDURE SetFillperimeter (handle: sINTEGER; border: BOOLEAN): BOOLEAN;
PROCEDURE SetUserfillpattern (handle: sINTEGER; VAR pat: ARRAY OF LOC);
(*-- VDI-Control -----------------------------------------------------*)
PROCEDURE OpenWorkstation (VAR in: ARRAY OF LOC;
VAR handle: sINTEGER;
VAR out: ARRAY OF LOC);
PROCEDURE CloseWorkstation (handle: sINTEGER);
PROCEDURE OpenVirtual (VAR in: ARRAY OF LOC;
VAR handle: sINTEGER;
VAR out: ARRAY OF LOC);
PROCEDURE CloseVirtual (handle: sINTEGER);
PROCEDURE ClearWorkstation (handle: sINTEGER);
PROCEDURE UpdateWorkstation (handle: sINTEGER);
PROCEDURE LoadFonts (handle, select: sINTEGER): sINTEGER;
PROCEDURE UnloadFonts (handle, select: sINTEGER);
PROCEDURE SetClipping (handle: sINTEGER; VAR rect: ARRAY OF LOC; do: BOOLEAN);
(*-- VDI-Escape ------------------------------------------------------*)
PROCEDURE GetCharcells (handle: sINTEGER; VAR rows, colums: sINTEGER);
PROCEDURE ExitAlphamode (handle: sINTEGER);
PROCEDURE EnterAlphamode (handle: sINTEGER);
PROCEDURE AcursorUp (handle: sINTEGER);
PROCEDURE AcursorDown (handle: sINTEGER);
PROCEDURE AcursorRight (handle : sINTEGER);
PROCEDURE AcursorLeft (handle: sINTEGER);
PROCEDURE HomeAcursor (handle: sINTEGER);
PROCEDURE EraseEOS (handle: sINTEGER);
(* EOS = End of screen *)
PROCEDURE EraseEOL (handle: sINTEGER);
(* EOL = End of line *)
PROCEDURE AcursorAddress (handle, row, column: sINTEGER);
PROCEDURE CursorText (handle: sINTEGER; string: ARRAY OF CHAR);
PROCEDURE ReverseVideoOn (handle: sINTEGER);
PROCEDURE ReverseVideoOff (handle: sINTEGER);
PROCEDURE InqCursoraddress (handle: sINTEGER; VAR row, column: sINTEGER);
PROCEDURE InqTabletstatus (handle: sINTEGER): sINTEGER;
PROCEDURE Hardcopy (handle: sINTEGER);
PROCEDURE DisplayCursor (handle, x, y: sINTEGER);
PROCEDURE RemoveCursor (handle: sINTEGER);
PROCEDURE FormAdvance (handle: sINTEGER);
PROCEDURE OutputWindow (handle: sINTEGER; VAR pxy: ARRAY OF LOC);
PROCEDURE ClearDisplaylist (handle: sINTEGER);
PROCEDURE Bitimagefile (handle: sINTEGER; fileName: ARRAY OF CHAR;
aspect, scaling, numPts: sINTEGER;
VAR pxy: ARRAY OF LOC);
PROCEDURE GetPrinterscan(handle: sINTEGER; VAR gSlice, gPage, size, page, div: sINTEGER);
PROCEDURE PrintText (handle: sINTEGER; string: ARRAY OF CHAR);
PROCEDURE SelectPalette (handle, palette: sINTEGER): sINTEGER;
PROCEDURE GenerateTone (handle, freq, time: sINTEGER);
PROCEDURE ToneMultiflag (handle, action: sINTEGER);
PROCEDURE SetTabl